package actions;

import java.util.List;
import org.apache.log4j.Logger;
import beans.User;

import com.opensymphony.xwork2.ActionSupport;

import controllers.AbstractController;


public class GetUsers extends ActionSupport {

	private static final long serialVersionUID = 1164809814839976523L;

	private static final Logger LOGGER = Logger.getLogger(GetUsers.class);

	
	// -------------------------------------------------------------
	// Objects
	// -------------------------------------------------------------

	AbstractController controller = new AbstractController();

	private String search;
	private List<User> result;
	
	
	// -------------------------------------------------------------
	// Methods
	// -------------------------------------------------------------

	public String execute() {
		setResult(controller.getUsers(getSearch()));
		return SUCCESS;
	}


	public List<User> getResult() {
		return result;
	}


	public void setResult(List<User> result) {
		this.result = result;
	}


	public String getSearch() {
		return search;
	}


	public void setSearch(String search) {
		this.search = search;
	}



}
